<div class="xm-message-container">
    <app-message-item *ngFor="let item of messages; index as i" [index]="i" [message]="item"></app-message-item> 
</div>